import { Application } from 'egg';

export default (app: Application) => {
    const { CHAR } = app.Sequelize;
    const model = app.model.define('SearchResult', {
        search_result_id: { type: CHAR(32), primaryKey: true },//主键
        user_id: CHAR(32),//用户id
        search_result_user_id: CHAR(32),//搜索结果id
        school_id: CHAR(32),//学校id
        search_type: CHAR(1),//搜索类型（1：首页，2：搜索页）
        search_result_type: CHAR(1),//类型（1：会员搜索结果，2：游客搜索结果）,
        is_delete:{type:CHAR(1),defaultValue:'1'},
    }, { tableName: 't_search_result' });
    return model;
};
export class SearchResult {
    search_result_id: string;
    user_id: string;
    search_result_user_id: string;
    school_id: string;
    search_type: string;
    search_result_type: string;
    is_delete:string;
}